#pragma once


// CGDBTreeCtrl

class CGDBTreeCtrl : public CTreeCtrl
{
	DECLARE_DYNAMIC(CGDBTreeCtrl)

public:
	CGDBTreeCtrl();
	virtual ~CGDBTreeCtrl();

protected:
	CImageList	m_il;
	CString		m_strPath;

	IWorkspaceFactoryPtr m_pWorksFactory;
	IWorkspacePtr		m_pWorkspace;

public:
	BOOL	SetPath(CString strGdbPath);
	BOOL	Populate();

protected:
	void	Cleanup();

protected:
	DECLARE_MESSAGE_MAP()
public:
	afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct);
	afx_msg void OnSize(UINT nType, int cx, int cy);
	afx_msg void OnNMClick(NMHDR *pNMHDR, LRESULT *pResult);
	virtual BOOL PreCreateWindow(CREATESTRUCT& cs);
	afx_msg void OnNMRClick(NMHDR *pNMHDR, LRESULT *pResult);
	afx_msg void OnNMDblclk(NMHDR *pNMHDR, LRESULT *pResult);
	afx_msg void OnGdbTreeRefresh();
};


